package ai.llz.ai_pro;

import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.io.FileNotFoundException;

@RestController
public class AiProController {
    @Resource
    private TableService service;

    @PostMapping("/query")
    public String getResult(@RequestBody String input){
        try {
            return service.getResult(input);
        } catch (Exception e) {
            return "系统出错啦";
        }
    }

}
